Apparatus and method for controlling an echo canceler

ABSTRACT

An echo canceler (10) is controlled and operated during hangover time between a double talk condition and a single talk condition for a more natural residual echo cancellation. The adaptive gain and the residual suppression threshold necessary for controlling an adaptive filter and a residual echo suppressor, respectively, are computed such that their respective values increase gradually and smoothly from predetermined minimum values to predetermined maximum values during the hangover time.

TECHNICAL FIELD OF THE INVENTION

This invention relates in general to the field of telephone networks and communications, and more particularly the present invention relates to apparatus and a method for controlling an echo canceler.

BACKGROUND OF THE INVENTION

Echo cancelers are typically voice operated devices positioned in the telephone network to improve the quality of voice and data transmissions by reducing the amount of echoes in the transmission. Echoes are generally caused by imperfect impedance matching in the 2-wire to 4-wire interfaces in the network. The echo canceler receives the transmitted signal, generates an estimate of the echo in the signal, and then subtracts the estimate from the transmitted signal. Since the amount of echo can vary during a telephone call as well as from call to call, the task of echo cancellation is a challenging problem not satisfactorily resolved by conventional echo cancelers. This task is even further complicated by the peculiarities of human hearing.

In general, the far-end speech signal is received and perceived by an echo canceler as the sum of near-end speech and echo. The echo canceler generally includes an adaptive filter to generate the echo estimate to cancel the echo in the far-end speech signal. Since this cancellation may not be complete, a non-linear processor is usually implemented to suppress the residual echo or the difference between the actual echo and the estimate of the echo. The adaptive filter is generally controlled by a parameter commonly called the adaptive gain. The non-linear processor is controlled by a parameter commonly called the residual suppression threshold. Therefore, the task of echo cancellation becomes the problem of computing the values for these parameters and providing the computed parameter values to the adaptive filter and non-linear processor at the correct time instances.

In the telephony industry, the terms "single talk", "double talk" and "soft double talk" describe the various conditions where the signal received by the echo canceler contains either all echo, no echo, and a combination of near-end speech and echo, respectively. Typically, both the adaptive gain and the residual suppression threshold parameters are both set at their respective minimum values during double talk, and at maximum values during single talk. However, during the transitional gray area between double talk and single talk conditions, the conventional method, of holding the parameter values at the minimum up to the instance the single talk condition is detected, has been proven unsatisfactory. The abrupt switch from the parameter minimum values to the maximum values demands an extremely accurate detection of the single talk condition. Inaccuracy may result in no echo canceling during an initial period of single talk, or maximum echo canceling during a latter period of hangover time where some information content may be present.

Accordingly, it is advantageous to gradually vary the adaptive filter and non-linear processor control parameters during hangover time. The result is a more desirable natural transition period between double talk and single talk.

SUMMARY OF THE INVENTION

In accordance with the present invention, apparatus and a method for controlling an echo canceler are provided which substantially eliminate or reduce disadvantages and problems associated with prior echo cancelers.

In one aspect of the present invention, an echo canceler is controlled and operated during hangover time between a double talk condition and a single talk condition for a more natural residual echo cancellation. The adaptive gain and the residual suppression threshold necessary for controlling an adaptive filter and a residual echo suppressor, respectively, are computed such that their respective values increase gradually and smoothly from predetermined minimum values to predetermined maximum values during the hangover time.

In another aspect of the present invention, adaptive gain modifying values and residual suppressor threshold modifying values are computed and subtracted from the optimum or maximum values of the adaptive gain and residual suppression threshold to compute for the adaptive gain and residual suppression threshold values.

In yet another aspect of the present invention, a counter is initialized and enabled to count during the hangover time. The adaptive gain modifying values and residual suppressor threshold modifying values are determined and then stored in look-up tables accessible by using the counter value to index the tables.

An important technical advantage of the present invention is a more desirable and more natural residual echo canceling during the hangover time between double talk and single talk.

BRIEF DESCRIPTION OF THE DRAWINGS

For a better understanding of the present invention, reference may be made to the accompanying drawings, in which:

FIG. 1 is a greatly simplified block diagram of an echo canceler;

FIG. 2 is a block diagram of an echo canceler block in the echo canceler;

FIG. 3 is a block diagram of an echo engine in the echo canceler;

FIG. 4 is a plot showing the input and output characteristics of the non-linear processor;

FIG. 5 is a flowchart describing the algorithm for computing adaptive filter and non-linear processor control parameters;

FIG. 6 is a short term power versus time plot describing hangover time;

FIG. 7 is plot of a prior implementation of residual suppression threshold versus time before, during and after hangover time; and

FIG. 8 is a plot of residual suppression threshold or adaptive gain versus time in accordance with the teachings of the present invention.

DETAILED DESCRIPTION OF THE INVENTION

With reference to the drawings, FIG. 1 is a greatly simplified block diagram of an echo canceler 10 operating at the DS1 level. The architecture of echo canceler 10 may be grouped into two logic blocks: a DS1 block 12 and an echo canceler block 14. DS1 block 12 includes microprocessors and circuitry primarily serving as an interface between echo canceler 10 and the telephone network (not shown). For example, DS1 block 12 performs all relevant tasks related to multiplexing and demultiplexing the twenty-four channels in the DS1 streams to and from the tail or near-end 16 and the long or far-end 18 sides of echo canceler 10. DS1 block 12 may also handle alarms and some digital signal processing functions as known in the telephony art. In addition, DS1 block provides echo canceler block 14 channel signals x_(R) and y_(R) 20 and 21 from far-end 18 and near-end 16, respectively, and also accepts signals r_(R) processed by echo canceler block 14 to be transmitted to far-end 18. A number of status and control signals 24 are passed between DS1 block 12 and echo canceler block 14. Signals x_(R), Y_(R) and r_(R) 20-22 are discussed in more detail below in conjunction with FIG. 3.

Referring to FIG. 2, a more detailed block diagram of echo canceler block 14 is shown. A circuitry 30 serves as an interface between DS1 block 12 and N echo engines 32-35. Typically, N is equal to 24, where each echo engine serves to cancel out the echoes in each of the 24 channels in DS1. A data bus 36 couples DS1 interface circuitry 30 and echo engines 32-35. Echo engines 32-35 are coupled to a microprocessor 40 by a control bus 38. Microprocessor 40 computes the adaptive gain, κ, and residual suppression threshold, RST, parameters and supplies them to echo engines 32-35. Another circuitry 42 is coupled between microprocessor 40 and DS1 block 12 serving as an interface for the status and control signals 24 therebetween.

FIG. 3 provides a more detailed block diagram of one echo engine 32 which is also representative of the other echo engines 33-35. The signal received by echo canceler 10 or echo engine 32 is signal y_(R) 21, which is the sum of near-end signal s_(R) 50 and echo e_(R) 52. In the preferred embodiment of the instant invention, microprocessor 40 supplies computed adaptive gain value κ to a correlator 54, which also receives a far-end signal x_(R) 20 Correlator 54 performs adaptive control of the filter coefficients for an adaptive filter 56. Adaptive filter 56 produces an echo estimate e_(R) 58, which is subtracted from y_(R) 21 to yield a signal w_(R) 60. Equations governing adaptive filter 56 are: ##EQU1## where μ is a leak constant as known in the art.

Since the echo estimation may not be perfect, signal w_(R) 60 may contain residual echoes. Microprocessor 40 further supplies a residual suppression threshold value RST to a non-linear processor (NLP) or residual suppressor 62, which further reduces the amount of echo in the speech signal to produce signal r_(R). Referring to FIG. 4, the transfer function of non-linear processor 62 is shown. Inputs less than the residual suppression threshold value RST are suppressed, and inputs above the threshold are passed to the output. As can be seen from FIG. 4, the input-output characteristic of non-linear processor 62 is symmetric and is usually referred to as a center clipper. The output signal r_(R) of non-linear processor 62 can be summarized by the following: ##EQU2## where t_(R) is a noise signal of appropriate levels for noise-matching purposes, as determined by algorithms known in the art. Additionally, echo engine 32 also includes circuitry 64 which estimates or computes the level or power of signals x_(R), y_(R) and w_(R) and supplies the computed signal powers to microprocessor 40.

Referring to FIG. 5, a simplified flowchart depicting the preferred algorithm executed by microprocessor 40 for computing the adaptive gain K and residual suppression threshold RST is shown. The algorithm maintains a double talk counter DBCTR, which is decremented in block 70. The signal powers for x_(R), y_(R) and w_(R) are read from echo engines 32-35, as shown in block 72, and a determination is made as to whether a double talk condition exists, as shown in block 74.

The double talk condition is determined by examining and comparing the signal powers of x_(R), y_(R) and w_(R), and is summarized below.

    ______________________________________                                         Power Comparisons    Condition                                                 ______________________________________                                         (a) P.sub.y  > P.sub.x                                                                              double talk                                               (b) P.sub.y  < P.sub.x                                                                              double talk                                               (c) P.sub.y  <≈ P.sub.x  and                                           (1) P.sub.w  < P.sub.y  or                                                                          single talk                                               (2) P.sub.w  <≈ P.sub.y                                                                     soft double talk                                          ______________________________________                                    

P_(x), P_(y) and P_(w) are computed power levels of signals x_(R), y_(R) and w_(R), respectively. In comparison (a) , where P_(y) >P_(x), signal y_(R) is probably predominantly near-end speech, and therefore double talk exists. Where P_(y) <P_(x), shown as comparison (b), the speech signal probably contains no echo. In comparison (c) (1), where P_(y) <≈P_(x) and P_(w) <P_(y), signal y_(R) is probably mostly echo, which indicates a single talk condition. In (c) (2), where P_(y) <≈P_(x) and P₂ <≈P_(y) y_(R) probably contains a combination of echo and near-end speech, which is commonly called soft double talk. The algorithms for determining double talk, single talk and soft double talk are quite involved, and therefore the table above merely presents a simplified scheme for their determination. The determination of these conditions is known in the art and not within the scope of the present invention.

By examining the power levels of the signals, if a double talk condition exists, then the double talk counter DBCTR is set to a predetermined maximum value, as shown in block 76. In this manner, DBCTR remains at its maximum value as long as double talk conditions exist. In the preferred embodiment of the instant invention as implemented within the EC24 echo canceler manufactured by DSC Communications Corporation of Plano, Tex., the maximum value for DBCTR is 60, where the algorithm shown in FIG. 5 is executed approximately every four milliseconds. Therefore, the maximum value of DBCTR is dependent on its application and may be experimentally determined.

Proceeding to block 78, since a double talk condition exists, the adaptive gain κ and residual suppression threshold RST are set to zero, for minimal or no echo cancellation. The values of κ and RST are then written into the respective echo engine.

On the other hand, if the determination in block 74 assessed that there is probably no double talk, the optimal values for the adaptive gain, κ_(OPT), and residual suppression threshold, RST_(OPT), are computed, as shown in block 82. The optimal κ and RST values may have been determined and calculated previously and stored in a look-up table. Please consult the Appendix for an example of the optimum κ and RST look-up tables formulated for DSC's EC24 Echo Canceler. The κ_(OPT) table is labeled as "κ OPTIMUM TABLE" and the RST_(OPT) table is labeled as "CCT TBL" in the Appendix. A further determination is made in block 84 as to whether a soft double talk condition exists. If a soft double talk condition exists, the double talk counter DBCTR is set to its maximum value once again, as shown in block 88. In block 86, the adaptive gain κ and the residual suppression threshold RST are computed by the following equations:

    κ=κ.sub.OPT -F(DBCTR)                          (4)

    RST=RST.sub.OPT -G(DBCTR),                                 (5)

where F and G represent adaptive gain κ and residual suppression threshold RST functions implemented as look-up tables. The tables are shown as "KSSDKM" and "LWRCCT" tables in the Appendix. It can be seen that the double talk counter DBCTR is used as an index into the look-up tables F and G. Therefore, as shown in Equations (4) and (5), the optimum κ and RST values are modified by some stored value depending on the value of DBCTR. The values in the look-up tables are experimentally determined and may therefore be hardware dependent. Subsequently, the computed values of κ and RST are supplied to the echo engines 32-35.

Therefore, as long as double talk or soft double talk conditions exist, the double talk counter DBCTR remains at its maximum value. When the double talk condition expires, the value of DBCTR decrements with each iteration of the algorithm, eventually reaching zero, which corresponds to a single talk condition. Hangover time corresponds to the interval while DBCTR is between its maximum value and zero. Accordingly, the adaptive gain κ and the residual suppression threshold RST are set depending on the value of DBCTR by the table look-up operations. In the exemplary implementation, as shown in the Appendix, the computed values of κ and RST increases as F and G decreases (and DBCTR decreases), although other implementations yielding a gradual and smooth κ and RST values during the hangover time are also contemplated and within the scope of the present invention. For example, the adaptive gain κ and the residual suppression threshold RST themselves may be computed and stored in look-up tables.

Referring to FIG. 6, a short-term power plot of a typical speech signal is shown The period t<T₀ is deemed as active by comparing the speech signal short-term power with a certain fixed threshold as known in the art. At time t>T₁, the speech signal short-term power is essentially zero, marking the silent time period. Hangover occurs between the active and silent time periods, where the short-term power level of the speech signal is below the threshold but is non-zero. Accordingly, there is information content in the speech signal during the hangover time that is perceivable by the human ear.

Referring to FIG. 7, a plot of a conventional implementation of adaptive gain κ and residual suppression threshold RST is shown. The parameters κ and/or RST are set to the minimum values during double talk. They remain at the minimum during the entire duration of hangover time, T₀ <t<T₁, and set to the maximum values at t=T₁. The abrupt transition at may result in unnatural echo canceling. Accordingly, this method requires an extremely accurate determination of the occurrence of single talk or when Y_(R) is echo only. Inaccuracy would result in no echo cancelling at all during some periods of single talk, or maximum echo cancelling during some period of hangover time where some information content may be present.

Referring to FIG. 8, the preferred embodiment of the present invention provides for smooth transitional values during the hangover time for the adaptive gain κ and residual suppression threshold RST. The parameters gradually increase from their minimum values to their maximum values during hangover time. The parameter values are determined experimentally and are implemented by look-up table as described above. Examples of the look-up tables implemented for the EC24 are shown in the Appendix.

It is apparent that by increasing the echo canceler control parameter values κ and RST gradually, the need for extremely accurate determinations of double talk and single talk transitions is eliminated since the need to make a black-and-white decision is obviated. Additionally, a higher quality and more natural voice transmission is achieved.

Although the present invention has been described in detail, it should be understood that various changes, substitutions and alterations can be made thereto without departing from the spirit and scope of the present invention as defined by the appended claims. ##SPC1## 

What is claimed is:
 1. A method for controlling an echo canceler having an adaptive filter, comprising the steps of:determining a beginning of a transitional hangover time between double talk or soft double talk, and single talk conditions; computing an adaptive filter gain for time instances during said transitional hangover time, said computed gain varying gradually depending on an amount of time lapse from the beginning of said transitional hangover time from a first predetermined value to a second predetermined value; and providing said adaptive filter with said computed gain at each said time instance.
 2. The method, as set forth in claim 1, wherein said echo controller further employing a residual echo suppressor controllable by a residual suppression threshold parameter, the method further comprising the steps of:computing said residual suppression threshold for time instances during said transitional hangover time, said computed threshold varying gradually depending on an amount of time lapse from the beginning of said transitional hangover time from a first predetermined value to a second predetermined value; and providing said residual echo suppressor with said computed threshold at each said time instance.
 3. The method, as set forth in claim 1, wherein said computing step computes said adaptive gain increasing from said first predetermined value which is less than said second predetermined value to said second predetermined value.
 4. The method, as set forth in claim 2, wherein said computing step computes said residual suppression threshold increasing from said first predetermined value which is less than said second predetermined value to said second predetermined value.
 5. The method, as set forth in claim 1, further comprising the step of storing said computed adaptive gains for said time instances in a look-up table.
 6. The method, as set forth in claim 2, further comprising the step of storing said computed residual suppression thresholds for said time instances in a look-up table.
 7. The method, as set forth in claim 1, further comprising the steps of:initializing and enabling a counter for timekeeping during said hangover time; and said adaptive gain computing step includes the steps of:accessing a look-up table having a plurality of adaptive gain modifying values; subtracting from a predetermined optimum adaptive gain value an adaptive gain modifying value accessed from said look-up table as indexed by the value of said counter.
 8. The method, as set forth in claim 2, further comprising the steps of:initializing and enabling a counter for timekeeping during said hangover time; and said residual suppression threshold computing step includes the steps of:accessing a look-up table having a plurality of residual suppression threshold modifying values; subtracting from a predetermined optimum residual suppression threshold value a residual suppression threshold modifying value accessed from said look-up table as indexed by the value of said counter.
 9. The method, as set forth in claim 2, wherein said hangover time determining step comprises the steps of:detecting a double talk condition; detecting a soft double talk condition; initiating a counter and begin counting in response to detecting an absence of double talk and soft double talk conditions being indicative of a single talk condition; and computing said adaptive filter gain and residual suppression threshold in response to the value of said counter.
 10. The method, as set forth in claim 9, wherein said echo canceler receives far-end signal X_(R), and near-end signal Y_(R), and generates a signal W_(R) after subtracting from said Y_(R) an estimated echo, said hangover time determining step further comprising the steps of:comparing the power levels of X_(R) and Y_(R) signals to determine the presence of double talk; and comparing the power levels of X_(R) and Y_(R) signals and the power levels of Y_(R) and W_(R) signals to determine the presence of single talk and soft double talk.
 11. A method for controlling an echo canceler having an adaptive filter controllable by an adaptive gain, and a residual echo suppressor controllable by a residual suppression threshold, the method comprising the steps of:determining a transitional hangover time between double talk or soft double talk and single talk conditions; initializing and enabling a counter for timekeeping during said hangover time; accessing a first look-up table having a plurality of adaptive gain modifying values; accessing a second look-up table having a plurality of residual suppression threshold modifying values; subtracting from a predetermined optimum adaptive gain value an adaptive gain modifying value accessed from said first look-up table and indexed by said counter value for computing said adaptive gain, said computed adaptive gain varying gradually from a first predetermined value to a second predetermined value depending on the value of said counter; subtracting from a predetermined optimum residual suppression threshold value a residual suppression threshold modifying value accessed from said second look-up table as indexed by the value of said counter for computing said residual suppression threshold, said computed residual suppression threshold varying gradually from a third predetermined value to a fourth predetermined value depending on the value of said counter; providing said adaptive filter with said computed gain and said residual echo suppressor with said computed residual suppression threshold.
 12. Apparatus for controlling an echo canceler having an adaptive filter controllable by an adaptive gain, and a residual echo suppressor controllable by a residual suppression threshold, the apparatus comprising:means for determining the beginning of a transitional hangover time between double talk or soft double talk and single talk conditions; a counter being initialized at the beginning of said transitional hangover time and for timekeeping during said hangover time; means for computing an adaptive filter gain for time instances during said transitional hangover time, said computed gain varying gradually depending on an account of time lapse from the beginning of said transitional hangover time from a first predetermined value to a second predetermined value; computing said residual suppression threshold for time instances during said transitional hangover time, said computed threshold varying gradually depending on an amount of time lapse from the beginning of said transitional hangover time from a third predetermined value to a fourth predetermined value; and means for providing said adaptive filter with said computed gain and said residual echo suppressor with said computed residual suppression threshold.
 13. The apparatus, as set forth in claim 12, further comprising:a first look-up table having a plurality of adaptive gain modifying values; a second look-up table having a plurality of residual suppression threshold modifying values; means for subtracting from a predetermined optimum adaptive gain value an adaptive gain modifying value accessed from said first look-up table and indexed by said counter value for computing said adaptive gain, said computed adaptive gain varying gradually from a first predetermined value to a second predetermined value; and means for subtracting from a predetermined optimum residual suppression threshold value a residual suppression threshold modifying value accessed from said second look-up table as indexed by the value of said counter for computing said residual suppression threshold, said computed residual suppression threshold varying gradually from a third predetermined value to a fourth predetermined value. 